using DevExpress.XtraEditors.DXErrorProvider;
using NAGFwk.UI.Properties;

namespace NAGFwk.UI
{
    public class ValidationRulesHelper
    {
        static ConditionValidationRule _ruleIsNotBlank = null;
        public static ConditionValidationRule RuleIsNotBlank
        {
            get
            {
                return _ruleIsNotBlank ?? (_ruleIsNotBlank = new ConditionValidationRule
                {
                    ConditionOperator = ConditionOperator.IsNotBlank,
                    ErrorText = Resources.RuleIsNotBlankWarning,
                    ErrorType = ErrorType.Critical
                });
            }
        }
    }
}
